using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Business_Layer;
using DTO;
using System.Collections.Generic;
public partial class CategoryControl : System.Web.UI.UserControl
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            this.FillCategories();
        }
    }

    void FillCategories()
    {
        //Category_BUS
        //String sql = "SELECT * FROM Categories";
        //DataTable Categories = Database.GetData(sql);

        GridView1.DataSource = Category_BUS.getAll();
        GridView1.DataBind();
    }
}
